//
//  FoundationExample.swift
//  SwiftCode
//
//  Created by yuhus on 2023/10/26.
//

import Foundation

class FoundationExample: ListViewController {
  override func getItemCount() -> Int {
    data.count
  }
  
  override func getItem(_ indexPath: IndexPath) -> Item {
    data[indexPath.row]
  }
  
  private lazy var data: [Item] = [
    .init(title: "Dates and Times", description: "时间和日期", type: DatesAndTimesExample.self),
    .init(title: "Errors and Exceptions", description: "响应与 API 交互中的问题情况，以更好地调试", type: ErrorsExample.self),
    .init(title: "Archives and Serialization", description: "将对象和值转换为属性列表、JSON和其他二进制表示形式。", type: CodableExample.self),
  ]
}
